<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script> <script> var Title = $('<textarea />').html("Chris' corner").text(); console.log(Title); </script>